package cn.shentianlan.controller;

import cn.shentianlan.domain.dto.StudentCourseDTO;
import cn.shentianlan.domain.entity.Student;
import cn.shentianlan.service.StudentCourseService;
import cn.shentianlan.utils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author 陈俊源
 * @Description TODO
 * @Date 2021/5/4
 * @Version 1.0
 */
@RestController
@RequestMapping("/studentCourse")
public class StudentCourseController {

    @Autowired
    private StudentCourseService studentCourseService;
    @RequestMapping("/save")
    public Result save(StudentCourseDTO studentCourseDTO){
        Result result = studentCourseService.save(studentCourseDTO);
        return result;
    }

    @RequestMapping("/delete")
    public Result delete(StudentCourseDTO studentCourseDTO){
        Result result = studentCourseService.delete(studentCourseDTO);
        return result;
    }

}
